<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Document</title>
    <style>
        #pink-div{
          display:inline-block;
          vertical-align:top;
          height:100px;
          width:100px;
          background:pink;
        }

        #red-div{
          display:inline-block;
          vertical-align:baseline;
          height:100px;
          width:100px;
          background:red;
        }

        #container .hide {
          display:none;
        }


    </style>
</head>
<body>
    <div id="container" style="border:1px solid #000;display:inline-block;">
      <div id="pink-div"></div>
      <div id="red-div"></div>
      <span style="line-height:200px;border:1px solid #000;">xxxxx</span>
    </div>
</body>
</html>